<?php
define("_needlogin", "1");
define("_access", "1");
include_once("include/db.config.php"); 
?>
<!DOCTYPE html>
<html>
<?php include("include/head.php"); ?>
<body style="padding-bottom:100px;">
<?php include("include/nav.php"); ?>

<link rel="stylesheet" type="text/css" href="./source/c3.min.css">

<div id="chal-solves-window" class="reveal-modal" data-reveal>
    <h3>已解决的队伍 (无顺序)</h3>
    <table>
        <thead>
            <tr>
                <td><b>Name</b></td>
            </tr>
        </thead>
        <tbody id="chal-solves-names">
        </tbody>
    </table>
    <a class="close-reveal-modal" data-reveal-id="chal-window">&#215;</a>
</div>

<div id="chal-window" class="reveal-modal" data-reveal>
    <div class="row">
        <h3 class='chal-name'></h3>
        <h4 class="chal-value"></h4>
        <p><i><a data-reveal-id="chal-solves-window" class="chal-solves"></a></i></p>
        <p class="chal-desc"></p>
        
        <input id="answer" type="text" placeholder="Flag">
        <input type="hidden" id="nonce" name="nonce" value="<?php echo md5(md5($_SESSION['team']['password']));?>">
        <button id="submit-key">提交</button>
        
        <input id="chal-id" type="hidden">
    </div>
    <a class="close-reveal-modal">&#215;</a>
</div>

<div class="row">
    </br>
    <h1 class="text-center">题目</h1>
    <div class="large-12 columns">
        <table id='challenges'>
        </table>
    </div>
</div>
<?php include("include/script.php"); ?>
<script src="./source/moment.min.js"></script>
<script src="./source/d3.min.js"></script>
<script src="./source/c3.min.js"></script>
<script src="./source/chalboard.js"></script>
</body>
</html>